package com.zggk.framework.controller.score;

import javax.servlet.http.HttpServletRequest;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import com.platform.common.utils.JsonUtils;
import com.platform.common.utils.PageUtils;
import com.platform.framework.controller.BaseController;
import com.zggk.framework.entity.score.GjContenthigh;
import com.zggk.framework.service.score.GjContenthighService;

/**
 * @Description 
 * @author 张立增[zhanglizeng] Tel：18860126570
 * @email 1472052711@qq.com
 * @date 2020-02-26 11:30:46
 */
@RestController
@RequestMapping("/gjContenthigh")
public class GjContenthighController extends BaseController{

    @Autowired
    GjContenthighService gjContenthighService;
    
    
	/**
	 * @Description 得到列表数据
	 * @author 张立增
	 * @Date 2020年2月26日 下午9:44:26
	 */
	@RequestMapping(value="/getDataGridBySearchContent",method= {RequestMethod.POST,RequestMethod.GET})
	public String getDataGridBySearchContent(HttpServletRequest request) throws Exception{
		String searchKey = request.getParameter("searchKey"); 
		Pageable pageable = null;    
		try {
			pageable = PageUtils.dealminiRequest(request);
		} catch (Exception e) {
			e.printStackTrace();
		}
		Page<GjContenthigh> pages = gjContenthighService.getDataGridBySearchContent(searchKey,pageable);
	    return JsonUtils.dealMiniPage(pages);
	}
   
}
